package com.netease.pris.activity.view;

import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.Color;
import android.net.Uri;
import android.text.method.ScrollingMovementMethod;
import android.util.AttributeSet;
import android.view.ViewGroup;
import android.view.animation.AlphaAnimation;
import android.view.animation.Animation;
import android.widget.FrameLayout;
import android.widget.ProgressBar;
import android.widget.TextView;
import com.netease.image.d;
import com.netease.image.video.a;
import com.netease.imageex.ImageViewScanActivity;
import com.netease.imageex.ImageViewTouch;
import com.netease.imageex.a.b;

public class PrisImageView extends FrameLayout
  implements ah, bp
{
  public ViewGroup a;
  public boolean b = true;
  public boolean c = true;
  private final int d = -1;
  private Context e;
  private ImageViewTouch f;
  private TextView g;
  private a h;
  private int i = -1;
  private int j;
  private int k;
  private Bitmap l;
  private ProgressBar m;
  private s n;
  private Animation o = new AlphaAnimation(1.0F, 0.0F);
  private Animation p = new AlphaAnimation(0.0F, 1.0F);
  private StringBuilder q = new StringBuilder();

  public PrisImageView(Context paramContext)
  {
    super(paramContext);
    a(paramContext);
  }

  public PrisImageView(Context paramContext, int paramInt, String paramString)
  {
    super(paramContext);
    a(paramContext);
  }

  public PrisImageView(Context paramContext, AttributeSet paramAttributeSet)
  {
    super(paramContext, paramAttributeSet);
    a(paramContext);
  }

  private void a(Context paramContext)
  {
    this.e = paramContext;
    this.l = null;
  }

  private void j()
  {
    this.f = ((ImageViewTouch)findViewById(2131558458));
    this.g = ((TextView)findViewById(2131558460));
    this.g.setMovementMethod(new ScrollingMovementMethod());
    this.a = ((ViewGroup)findViewById(2131558459));
    this.m = ((ProgressBar)findViewById(2131558461));
    this.f.a(true);
  }

  public TextView a()
  {
    return this.g;
  }

  public Object a(int paramInt1, int paramInt2, Object paramObject)
  {
    if (100 == paramInt2);
    while (true)
    {
      return this;
      this = null;
    }
  }

  public void a(float paramFloat)
  {
    this.f.a(paramFloat);
  }

  public void a(float paramFloat1, float paramFloat2)
  {
    if (this.f != null)
      this.f.a_(paramFloat1, paramFloat2);
  }

  public void a(int paramInt)
  {
    this.i = paramInt;
  }

  public void a(int paramInt1, int paramInt2)
  {
    this.j = paramInt1;
    this.k = paramInt2;
  }

  public void a(int paramInt, boolean paramBoolean)
  {
  }

  public void a(a parama)
  {
    this.h = parama;
  }

  public void a(b paramb)
  {
    if (paramb != null)
      this.f.a(paramb);
  }

  public void a(s params)
  {
    this.n = params;
  }

  public void a(boolean paramBoolean)
  {
    b(paramBoolean);
  }

  public boolean a(String paramString)
  {
    return false;
  }

  public void b(boolean paramBoolean)
  {
    this.o.setDuration(ImageViewScanActivity.f);
    this.p.setDuration(ImageViewScanActivity.f);
    if (paramBoolean)
    {
      this.g.setVisibility(0);
      this.a.setBackgroundColor(Color.argb(178, 0, 0, 0));
      this.a.setVisibility(0);
    }
    while (true)
    {
      return;
      this.g.setVisibility(8);
      this.a.setBackgroundDrawable(null);
      this.a.setVisibility(8);
    }
  }

  public boolean b()
  {
    if (this.f.d() < this.f.f());
    for (int i1 = 1; ; i1 = 0)
      return i1;
  }

  public boolean b(int paramInt1, int paramInt2, Object paramObject)
  {
    switch (paramInt2)
    {
    default:
    case 101:
    }
    while (true)
    {
      return true;
      a(((Boolean)paramObject).booleanValue());
    }
  }

  public boolean b(String paramString)
  {
    return false;
  }

  public void c(String paramString)
  {
    this.g.setText(paramString);
    if (paramString != null)
      this.g.setClickable(true);
  }

  public boolean c()
  {
    if (this.f.d() > 1.0F);
    for (int i1 = 1; ; i1 = 0)
      return i1;
  }

  public void d()
  {
    this.f.c();
  }

  public void e()
  {
    this.f.b();
  }

  public void e(int paramInt)
  {
    if (this.j == paramInt);
    while (true)
    {
      return;
      if (this.f != null)
        this.f.a(1.0F);
      this.j = paramInt;
    }
  }

  public a f()
  {
    return this.h;
  }

  public Bitmap g()
  {
    return this.f.g();
  }

  public void g(int paramInt)
  {
    if (this.h == null);
    while (true)
    {
      return;
      this.f.a(null, true, false);
      int i1 = 259;
      if (this.j == this.k)
        i1 = 260;
      this.m.setVisibility(0);
      this.b = false;
      this.q.setLength(0);
      d.a().a(this.q, 0, this.h.b().toString(), new bo(this), -1, -1, i1, this.i);
    }
  }

  public void h(int paramInt)
  {
  }

  public boolean h()
  {
    int i1 = 1;
    if ((this.m == null) || (this.m.getVisibility() != 0));
    while (true)
    {
      return i1;
      i1 = 0;
    }
  }

  public float i()
  {
    return this.f.d();
  }

  public void i(int paramInt)
  {
  }

  protected void onAttachedToWindow()
  {
    super.onAttachedToWindow();
  }

  protected void onDetachedFromWindow()
  {
    super.onDetachedFromWindow();
    if (this.f != null)
    {
      this.f.a(null, true, false);
      this.f = null;
    }
    if (this.h != null)
      this.h = null;
    this.o = null;
    this.p = null;
    this.e = null;
    if (this.l != null)
    {
      this.l.recycle();
      this.l = null;
    }
    if (this.m != null)
    {
      this.m.setVisibility(8);
      this.m = null;
    }
  }

  protected void onFinishInflate()
  {
    super.onFinishInflate();
    j();
  }
}

/* Location:           D:\android\hack\dex2jar-0.0.9.8\classes_dex2jar.jar
 * Qualified Name:     com.netease.pris.activity.view.PrisImageView
 * JD-Core Version:    0.6.0
 */